Conventional resource management strategies for real-time application programs have been unsatisfactory. A "real-time application program" is an application program that must execute in a predictable and timely fashion in order to operate properly. Many current efforts to provide resource management for real-time application programs may only manage a static set of resources. In other words, the resource set may not change during the course of operation of the system. Another limitation of many conventional resource management strategies is that they only accommodate one type of resource (i.e., the resources must be homogeneous). An additional limitation of many conventional resource management strategies is that they rely upon the resource or the application program to determine which application program should be allocated a resource and what quantity of the resource should be allocated. Another conventional approach has been to rely upon human experts to correctly assign priorities to tasks within the system. Unfortunately, such human experts typically cannot accurately assign priorities for a dynamic mix of real-time application programs.
The process of determining which threads to execute at which times is generally termed "scheduling" a computer system's CPU. Conventional CPU scheduling is an example of an unsatisfactory conventional resource management strategy for real-time application. A typical conventional scheduling strategy is to divide the processor time resource into "time slices" having a uniform length. At the expiration of a time slice, a conventional scheduler identifies a thread to execute during the next time slice. In a balanced allocation scheme, each ready thread receives one time slice in turn, so that the processor time is divided evenly among the ready threads. In a weighted allocation scheme, each thread specifies the percentage of total processor time it is to receive. The scheduler then uses an accounting process to keep track of the number of time slices each thread has received, and assigns the next time slice to the thread that is furthest from having received its specified percentage. Such time slice scheduling has two significant disadvantages. First, such time slice scheduling can be inefficient because it involves frequent reassignments of the processor. On the other hand, even the weighted allocation scheme does not take into account thread processor requirements finer than the overall percentage of processor time that must be used to successfully schedule multiple threads having significant processor time demands.
The way in which scheduling is performed can significantly impact a user's perception of whether individual threads are performing adequately. Modern multimedia applications, for example, often require substantial processor time, and appear to proceed slowly or jerkily if they do not receive it. To ensure adequate performance, conventional multimedia applications and other real-time applications typically secure exclusive use of the processor, to the exclusion of any other existing threads.
A hardware device connected to a computer system typically interacts with the computer system by raising an assigned one of a set of device interrupts. The computer system typically responds to the interrupt by executing an interrupt handling routine corresponding to the raised interrupt. In conventional operating systems, this device interrupt handling is typically performed preemptively by, when a device interrupt occurs, suspending the normal scheduled processing of threads while executing the interrupt processing routine. As a result, time-critical threads can be suspended for significant periods of time when their execution coincides with device interrupts.